﻿using BCEntity.WeChatComponent.WeChatMessagePushRecord;
using System;
using System.Collections.Generic;
using System.Text;

namespace BCData.WeChatComponent.WeChatMessagePushRecord
{
    /// <summary>
    /// 微信群发记录数据处理接口
    /// </summary>
    public interface IWeChatMessagePushRecordData
    {
        /// <summary>
        /// 添加群发记录
        /// </summary>
        /// <param name="weChatMessagePushRecordEntity">微信群发记录</param>
        /// <returns></returns>
        bool Add(WeChatMessagePushRecordEntity weChatMessagePushRecordEntity);
        /// <summary>
        /// 更新群发状态
        /// </summary>
        /// <param name="weChatMessagePushRecordEntity">微信群发记录</param>
        /// <returns></returns>
        bool UpdateMPStatus(WeChatMessagePushRecordEntity weChatMessagePushRecordEntity);
        /// <summary>
        /// /删除群发记录
        /// </summary>
        /// <param name="msgId">消息Id</param>
        void Delete(long msgId);
        /// <summary>
        /// 获取群发记录数据记录
        /// </summary>
        /// <param name="msgId">消息Id</param>
        /// <returns></returns>
        WeChatMessagePushRecordEntity GetEntity(long msgId);
        /// <summary>
        /// 获取群发记录数据记录
        /// </summary>
        /// <param name="mediaId">素材Id</param>
        /// <returns></returns>
        WeChatMessagePushRecordEntity GetEntity(string mediaId);
        /// <summary>
        /// 获取群发记录列表
        /// </summary>
        /// <param name="mediaId">素材Id</param>
        /// <param name="msgStatus">消息状态</param>
        /// <param name="dataCount">数据总数</param>
        /// <param name="pageIndex">当前页码</param>
        /// <param name="pageSize">每页数据条数</param>
        /// <returns></returns>
        IEnumerable<WeChatMessagePushRecordEntity> GetList(string mediaId,string msgStatus, DateTime? start, DateTime? end, out int dataCount, bool? ascending, int pageIndex = 1, int pageSize = 10);
    }
}
